import 'package:flutterapp/InitConfig.dart';

class ApiMapper {
  static String formatBaseUrl(String url, bool needSlash) {
    String cache = url.trim();
    if (!needSlash && cache.endsWith("/")) {
      cache = cache.substring(0, cache.length - 1);
    }
    return cache;
  }

  static final DEMO_URL = "${InitConfig.BASE_API_HOST}/demo/url";
  static final testUrl = "https://www.wanandroid.com/user/register";
}
